﻿using CardLogistics.Web.Components;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace CardLogistics.Web.MainPage.PutInCard.PutInCard
{
    public partial class MonthReportRpt : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                BindRpt();
            }
        }

        /// <summary>
        /// 绑定Rpt数据
        /// </summary>
        private void BindRpt()
        {
            string month = Request.QueryString["month"];//月份
            StringBuilder sbStr = new StringBuilder();
            sbStr.Append(" SELECT * FROM v_putincarddetailedrpt WHERE 1=1  and Issubmit=5");
            if (!string.IsNullOrEmpty(month))
            {
                sbStr.Append(" and to_char(PUTINDATE,'yyyy-MM') ='" + month.Trim() + "'");//年月
            }
            else
                sbStr.Append(" and 1<>1 ");
            sbStr.Append(" Order by PUTINNO");
            OracleXMLReportData.GenNodeXmlData(this, sbStr.ToString(), true);

        }
    }
}